<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ page import="java.util.*" %>
<%@ page import="cn.estore.entity.*" %>
<%@ page import="cn.estore.dao.*" %> 
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
<a href="login.jsp">登录</a>
<a href="zhuce.jsp">注册</a>
<%
ProductDao dao=new ProductDao();
List ProductList=(List)dao.selectAllProducts();
for(int i=0;i<ProductList.size();i++)
{
	Product e=(Product)ProductList.get(i);
%>
<table border="1" align="center" width="80%" height="136">
<tr>
<td width="40%" height="80" rowspan="5"><div align="center">
<img src="<%="productImages/"+e.getPicture()%>">
</div></td>
<td>
<div align="left">
商品：<%=e.getName() %>
</div>
<div align="left">
价格：<%=e.getMarketPrice() %>元
</div>
<div align="left">
简介：<%=e.getDescription() %>
</div>
<div align="left">
登录才能购买
</div>
</td>
</tr>
</table>
<%
}
%>
</body>
</html>